<%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<!DOCTYPE html>
<html>
 <head>
  <title>设备信息</title>
  <t:base type="jquery,easyui,tools,DatePicker"></t:base>
  <script type="text/javascript">
  //编写自定义JS代码
  </script>
 </head>
 <body>
  <t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" action="computerRoomController.do?setCost" tiptype="3" >
		
		<input id="id" name="id" type="hidden" value="${computerRoom.id }"> 
		<table style=" " cellpadding="0" cellspacing="1" class="formtable">
				<tr>
					<td align="right">
						<label class="Validform_label">
							金额(元)/小时:
						</label>
					</td>
					<td class="value">
						<input type="text" id="costPerHour" name="costPerHour" class="inputtxt" style="width: 120px" 
							 datatype="*" value="${computerRoom.costPerHour}"/>
						<span class="Validform_checktip"></span>
						<label class="Validform_label" style="display: none;">金额</label>
					</td>
				</tr> 
			</table>
		</t:formvalid>
 </body>
 <script>
 	 
 $(document).ready(function(){
	 $("#costPerHour").keyup(function () {
         var reg = $(this).val().match(/^-?\d*\.?\d{0,2}/);
         var txt = '';
         if (reg != null) {
             txt = reg[0];
         }
         $(this).val(txt);
         
         
     }).change(function () {
         $(this).keypress();
         var v = $(this).val();
         if (/\.$/.test(v))
         {
             $(this).val(v.substr(0, v.length - 1));
         }
     });
 });
 	
 </script>
  <script src = "webpage/com/mengtian_tech/device_mgr/device/deviceType.js"></script>		
